﻿// <copyright>
// Project: sofort.NET
// Date:  2014 - 02 - 04
// Copyright: Karl Haak 2014
// </copyright>
// <author>Karl Haak (www.karlhaak.de)</author>
using System;

namespace pay.sofort.Models
{
    public static class TPaySofort
    {
        public static T SetNew<T>(this T item, string username) where T : PaySofortBase, IPaySofort
        {
            item.DbGuid = Guid.NewGuid();
            item.CreatedAt = DateTime.Now;
            item.CreatedBy = username;
            return item;
        }
    }
}